package cn.zcscloud.mall.service;

import cn.zcscloud.mall.mbg.model.PmsProduct;
import cn.zcscloud.mall.vo.CreateVo;
import cn.zcscloud.mall.vo.PmsProductResult;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.transaction.annotation.Transactional;

import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.List;

public interface PmsProductService extends IService<PmsProduct> {

    Boolean updateByIds(PmsProduct pmsProduct, LambdaQueryWrapper<PmsProduct> lqw);
    @Transactional(rollbackFor = Exception.class)
    Boolean insert(CreateVo createVo,Integer code) throws InvocationTargetException, IllegalAccessException;

    @Transactional(rollbackFor = Exception.class)
    Boolean changeById(Long id, CreateVo createVo) throws InvocationTargetException, IllegalAccessException;

    Boolean deleteByIds(List ids,Integer code);

    @Transactional
    PmsProductResult seleteById(Long id) throws InvocationTargetException, IllegalAccessException;
}
